On Wayland it is possible to trigger area selection with a button
already being down. SelectArea would then react to the subsequent button
release without ever having seen a corresponding button down first,
leaving the start coordinates of the selection rectangle uninitialized.
Related: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/2761
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1825>
}
vfunc_button_release_event() {
+ if (this._startX === -1 || this._startY === -1)
+ return Clutter.EVENT_PROPAGATE;
+
this._result = this._getGeometry();
this.ease({
opacity: 0,